import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'

Vue.use(VueRouter)

  const routes = [
  {
    path: '/',
    name: 'Home',
    component: Home,
    meta:{
      isShowTab:true
    }
  },
  {
    path: '/classfily',
    name: 'classfily',
    component: () => import('../views/Classfily.vue'),
    meta:{
      isShowTab:true
    }
  },
  {
    path: '/cart',
    name: 'cart',
    component: () => import('../views/Cart.vue'),
    meta:{
      isShowTab:false
    }
  },
  {
    path: '/myself',
    name: 'myself',
    component: () => import('../views/Myself.vue'),
    meta:{
      isShowTab:true
    }
  },
  {
    path: '/list',
    name: 'list',
    component: () => import('../components/body/list'),
    meta:{
      isShowTab:false
    }
  },
  {
    path: '/login',
    name: 'login',
    component: () => import('../components/body/login'),
    meta:{
      isShowTab:false
    }
  },
  {
    path: '/register',
    name: 'register',
    component: () => import('../components/body/register'),
    meta:{
      isShowTab:false
    }
  }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
